from PyQt5.QtWidgets import QTreeWidgetItem
from PyQt5.QtCore import Qt

def MIBTreeGen(faWidget):
    MIB_Tree = QTreeWidgetItem(faWidget)
    MIB_Tree.setText(0, 'MIB Tree')
    
    iso = QTreeWidgetItem(MIB_Tree)
    iso.setText(0, 'iso')
    
    org = QTreeWidgetItem(iso)
    org.setText(0, 'org')
    
    dod = QTreeWidgetItem(org)
    dod.setText(0, 'dod')

    internet = QTreeWidgetItem(dod)
    internet.setText(0, 'internet')

    directory = QTreeWidgetItem(internet)
    directory.setText(0, 'directory')

    mgmt = QTreeWidgetItem(internet)
    mgmt.setText(0, 'mgmt')

    mib_2 = QTreeWidgetItem(mgmt)
    mib_2.setText(0, 'mib_2')

    system = QTreeWidgetItem(mib_2)
    system.setText(0, 'system')

    sysDescrItem = QTreeWidgetItem(system)
    sysDescrItem.setText(0, 'sysDescr')
    sysDescrItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.1.1.0')

    sysObjectIDItem = QTreeWidgetItem(system)
    sysObjectIDItem.setText(0, 'sysObjectID')
    sysObjectIDItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.1.2.0')

    sysUpTimeItem = QTreeWidgetItem(system)
    sysUpTimeItem.setText(0, 'sysUpTime')
    sysUpTimeItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.1.3.0')

    sysContactItem = QTreeWidgetItem(system)
    sysContactItem.setText(0, 'sysContact')
    sysContactItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.1.4.0')

    sysNameItem = QTreeWidgetItem(system)
    sysNameItem.setText(0, 'sysName')
    sysNameItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.1.5.0')

    sysLocationItem = QTreeWidgetItem(system)
    sysLocationItem.setText(0, 'sysLocation')
    sysLocationItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.1.6.0')

    sysServicesItem = QTreeWidgetItem(system)
    sysServicesItem.setText(0, 'sysServices')
    sysServicesItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.1.7.0')

    sysORLastChangeItem = QTreeWidgetItem(system)
    sysORLastChangeItem.setText(0, 'sysORLastChange')
    sysORLastChangeItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.1.8.0')

    sysORTableItem = QTreeWidgetItem(system)
    sysORTableItem.setText(0, 'sysORTable')
    sysORTableItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.1.9.0')
    
    interfaces = QTreeWidgetItem(mib_2)
    interfaces.setText(0, 'interfaces')
    interfaces.setData(0, Qt.UserRole, '1.3.6.1.2.1.2')
    
    ifTable = QTreeWidgetItem(interfaces)
    ifTable.setText(0, 'ifTable')
    ifTable.setData(0, Qt.UserRole, '1.3.6.1.2.1.2.2')
    
    ifEntry = QTreeWidgetItem(ifTable)
    ifEntry.setText(0, 'ifEntry')
    ifEntry.setData(0, Qt.UserRole, '1.3.6.1.2.1.2.2.1')
    
    ifIndexItem = QTreeWidgetItem(ifEntry)
    ifIndexItem.setText(0, 'ifIndex')
    ifIndexItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.2.2.1.1')
    
    ifDescrItem = QTreeWidgetItem(ifEntry)
    ifDescrItem.setText(0, 'ifDescr')
    ifDescrItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.2.2.1.2')
    
    ifTypeItem = QTreeWidgetItem(ifEntry)
    ifTypeItem.setText(0, 'ifType')
    ifTypeItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.2.2.1.3')
    
    ifMtuItem = QTreeWidgetItem(ifEntry)
    ifMtuItem.setText(0, 'ifMtu')
    ifMtuItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.2.2.1.4')
    
    ifSpeedItem = QTreeWidgetItem(ifEntry)
    ifSpeedItem.setText(0, 'ifSpeed')
    ifSpeedItem.setData(0, Qt.UserRole, '1.3.6.1.2.1.2.2.1.5')

    experimental = QTreeWidgetItem(internet)
    experimental.setText(0, 'experimental')

    private = QTreeWidgetItem(internet)
    private.setText(0, 'private')

    security = QTreeWidgetItem(internet)
    security.setText(0, 'security')

    snmpV2 = QTreeWidgetItem(internet)
    snmpV2.setText(0, 'snmpV2')
    return MIB_Tree
